//
//  WDExample.m
//  WDNetworking
//
//  Created by apple on 2017/5/20.
//  Copyright © 2017年 wintersal. All rights reserved.
//

#import "WDExample.h"
#import "WDBaseModel.h"
@implementation WDExample
- (void)demo
{
    WDBaseModel *baseModel = [[WDBaseModel alloc] init];
    baseModel.d = self;
    WDNetworking *net = [WDNetworking netWorkingWithBaseModel:baseModel];
    [net POST:@"http://api.84185858.com/index.php?" param:@{@"reqUrl":@"Common.queryBanner", @"sysCode":@"05"} success:^(BOOL success, id result) {
       if (success) {
           WDBaseModel *model = result;
           NSMutableArray *tmp = model.d;
           for (WDExample *item in tmp) {
               NSLog(@"%@", item.fBannerPicUrl);
           }
       }
       
   } faile:^(NSError *error) {
       NSLog(@"网络请求失败");
   }];
    
    
    /*[net GET:@"http://api.84185858.com/index.php?" param:@{@"reqUrl":@"Common.queryBanner", @"sysCode":@"05"} success:^(BOOL success, id result) {
        if (success) {
            WDBaseModel *model = result;
            NSMutableArray *tmp = model.d;
            for (WDExample *item in tmp) {
                NSLog(@"%@", item.fBannerPicUrl);
            }
        }
    } faile:^(NSError *error) {
        NSLog(@"网络请求失败");
    }];
    */
}


@end
